﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CNKI.TPI.Web.Search.Model;

namespace CNKI.TPI.Web.Search.IBLL
{
    /// <summary>
    /// 用户信息Service
    /// </summary>
    public interface IUserService
    {
        /// <summary>
        /// 检查用户合法性
        /// </summary>
        /// <param name="userName">用户名</param>
        /// <param name="password">密码</param>
        /// <param name="needPWD">是否验证密码</param>
        /// <returns>用户信息</returns>
        LoginUserInfo ValidateUser(string userName, string password, bool needPWD = true);

        /// <summary>
        /// 
        /// </summary>
        /// <param name="user"></param>
        /// <returns></returns>
        bool CheckUser(SYS_CMS_USER user);

        /// <summary>
        /// 获得所有用户
        /// </summary>
        /// <returns>用户信息列表</returns>
        DataTable GetAllUser();
              /// <summary>
        /// 获取登录失败次数
        /// </summary>
        /// <returns></returns>
        int GetFaidNum();
    }
}
